home *** CD-ROM | disk | FTP | other *** search
- Attribute VB_Name = "modJoin"
- Option Explicit
-
- Private Huffman As clsHuffman
-
- 'Declare the variable Bytes as of ChunkSize type
- Dim Bytes As ChunkSize
-
- Function JoinFile(FileName As String, Extension As String, Compress As Integer, NumOfSegments As Integer, DestinationPath As String) As Integer
- ' Filename = The original file
- ' Extension = Original Extension
- ' Compress = Compressed state
- ' NumOfSegments = Number of files to join
-
-
-
- On Error GoTo ErrorHandler
-
-
- 'Make sure the settings are correct
- Dim ErrorCode As Integer
- If NumOfSegments > 999 Then ' Ensure that the segment size is valid
- ErrorCode = 2
- GoTo ErrorHandler
- End If
-
- Dim SourceBytes As Long
- Dim SourceFile As String
- Dim DestinationFile As String
- Dim SegmentNumber As Integer
- Dim BytesDone As Long
- Dim FPath As String
- Dim FName As String
- Dim FNameNoExt As String
- Dim Remainingc FNamSid
- ErrorCode = 2
- GoTo ErrorHandler
- Eecls SPrrorH)
- Dup.